home *** CD-ROM | disk | FTP | other *** search
/ Precision Software Appli…tions Silver Collection 1 / Precision Software Applications Silver Collection Volume One (PSM) (1993).iso / tutor / asm1tut.exe / PUSHREGS.MAC < prev    next >
Text File  |  1989-10-16  |  1KB  |  50 lines

  1.  
  2.  
  3. PUSHREGS     MACRO  r1, r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12
  4.              IFNB   <r1>
  5.              push   r1
  6.              PUSHREGS  r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12
  7.              ENDIF
  8.              ENDM
  9.  
  10. POPREGS      MACRO  r1, r2, r3, r4, r5, r6, r7, r8, r9, r10, r11, r12
  11.              IFNB   <r12>
  12.              pop    r12
  13.              ENDIF      ;;--------
  14.              IFNB   <r11>      ;; all this is necessary because the
  15.              pop    r11        ;; assembler overflows on recursion
  16.              ENDIF      ;;--------
  17.              IFNB   <r10>
  18.              pop    r10
  19.              ENDIF      ;;--------
  20.              IFNB   <r9>
  21.              pop    r9
  22.              ENDIF      ;;--------
  23.              IFNB   <r8>
  24.              pop    r8
  25.              ENDIF      ;;--------
  26.              IFNB   <r7>
  27.              pop    r7
  28.              ENDIF      ;;--------
  29.              IFNB   <r6>
  30.              pop    r6
  31.              ENDIF      ;;--------
  32.              IFNB   <r5>
  33.              pop    r5
  34.              ENDIF      ;;--------
  35.              IFNB   <r4>
  36.              pop    r4
  37.              ENDIF      ;;--------
  38.              IFNB   <r3>
  39.              pop    r3
  40.              ENDIF      ;;--------
  41.              IFNB   <r2>
  42.              pop    r2
  43.              ENDIF      ;;--------
  44.              IFNB   <r1>
  45.              pop    r1
  46.              ENDIF      ;;--------
  47.              ENDM
  48.  
  49.  
  50.